from sklearn.linear_model import LinearRegression
# 定义数据集
x = [
    [10,10],
    [20,40]
]
y = [10,38]

model = LinearRegression()
model.fit(x,y)
coef = model.coef_
print(coef)